﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace GesParking
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void Form1_Load(object sender, EventArgs e)
        {
            UsersPL users = new UsersPL();
            Guid user1 = Guid.NewGuid();
            users.Add(user1, "Nome1");
            Guid user2 = Guid.NewGuid();
            users.Add(user2, "Nome2");

            ParksPL parques = new ParksPL();
            Guid parque1 = Guid.NewGuid();
            parques.Add(parque1, "parque1", 10);
            Guid parque2 = Guid.NewGuid();
            parques.Add(parque2, "parque2", 10);

            ParkingRegistryPL registo = new ParkingRegistryPL();

            registo.ParkIn(parque1, user1);
            registo.ParkIn(parque1, user2);
            registo.ParkOut(parque1, user1);

            registo.Save();
            users.Save();
            parques.Save();
        }
    }
}
